import org.apache.commons.codec.digest.DigestUtils;
import org.hashids.Hashids;

/**
 * @author colafries
 * @version v1.0
 * @ClassName testHash
 * @Description
 * @date Created in 2024/4/8
 **/
public class testHash {
    public static void main(String[] args) {
        final String SALT = "model_id";
        final int MIN_HASH_LENGTH = 18;

        Hashids hashids = new Hashids(SALT, MIN_HASH_LENGTH);
        String encryptString = hashids.encode(347L);

        System.out.println(encryptString.toUpperCase()); // Y5bAyr8dLO4

    }
}
